package com.atguigu.gmall.order.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

import java.util.concurrent.TimeUnit;

@Data
@Component
@ConfigurationProperties(prefix = "service.order")
public class OrderProperties{
    private Integer ttl;
    private TimeUnit unit = TimeUnit.MINUTES; //默认是分钟
}